﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using EPiServer;
using EPiServer.Core;

namespace EPiBoost.Core.Helpers
{
	public static class HttpContextHelper
	{
		public static PageData GetCurrentPageFromHttpContext()
		{
			var page = HttpContext.Current.Handler as PageBase;

			if (page == null)
			{
				return null;
			}
			return page.CurrentPage;
		}
	}
}
